/*
 *    Copyright (c) 2018-2025, boss All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the following disclaimer.
 * Redistributions in binary form must reproduce the above copyright
 * notice, this list of conditions and the following disclaimer in the
 * documentation and/or other materials provided with the distribution.
 * Neither the name of the boss developer nor the names of its
 * contributors may be used to endorse or promote products derived from
 * this software without specific prior written permission.
 * Author: boss
 */

package com.hopes.bizz.basic.park.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.hopes.bizz.basic.common.constant.enums.ParkBasicSysDictEnum;
import com.hopes.boss.admin.api.resolver.DictResolver;
import com.hopes.boss.admin.api.resolver.enums.AdminDictEnum;
import com.hopes.boss.common.entity.BaseLogicEntity;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 禁限控目录
 *
 * @author pig
 * @date 2023-10-23 13:50:28
 */
@Data
@TableName("base_park_forbidden_control")
@EqualsAndHashCode(callSuper = true)
@Schema(description = "禁限控目录")
public class BaseParkForbiddenControlEntity extends BaseLogicEntity {

    private static final long serialVersionUID = 1L;


	/**
	* 标识
	*/
    @TableId(type = IdType.ASSIGN_ID)
    @Schema(description="标识")
    private Long id;

	/**
	* 禁限控类型  1:禁止(淘汰)类  2:限(控)制类
	*/
    @Schema(description="禁限控类型")
    private String controlType;

	/**
	* 行业类型    1:石化化工 2:医药  3:轻工  4:民爆产品  5:其他
	*/
    @Schema(description="行业类型")
    private String tradeType;

	/**
	* 品名
	*/
    @Schema(description="品名")

    private String productName;

	/**
	* CAS号
	*/
    @Schema(description="CAS号")
    private String casNum;

	/**
	* 危险性类别
	*/
    @Schema(description="危险性类别")
    private String hazardClass;

	/**
	* 原因
	*/
    @Schema(description="原因")
    private String controlReason;

	/**
	* 政策依据
	*/
    @Schema(description="政策依据")
    private String policyBasis;

	/**
	* 别名
	*/
    @Schema(description="别名")
    private String productAlias;

	/**
	 * 附件
	 */
	@Schema(description="附件")
	private String attachment;

	/**
	* 备注
	*/
    @Schema(description="备注")
    private String remark;

	/**
	 * 机构ID
	 */
	@Schema(description="机构ID")
	private Long orgId;

	public String getOrgIdStr() {
		return DictResolver.getItemLabelByValue(AdminDictEnum.sys_company,this.orgId);
	}


	public String getControlTypeStr(){

		return DictResolver.getItemLabelByValue(ParkBasicSysDictEnum.control_type,this.controlType);

	}
	public String getTradeTypeStr(){
		return DictResolver.getItemLabelByValue(ParkBasicSysDictEnum.trade_type,this.tradeType);
	}


}
